#define _CRT_SECURE_NO_WARNINGS



#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
ll n, m, k;
ll com(ll x)
{
    if (n > m)
        swap(n, m);
    ll ans = 0;
    ll i_max = min(n, x - 1);
    for (ll i = 1; i <= i_max; i++)
    {
        ll j_min = (x + i - 1) / i;
        if (j_min > m)
            continue;
        ans += m - j_min + 1;
    }
    if (n >= x)
    {
        ll cnt = n - x + 1;
        ans += cnt * m;
    }
    return ans;
}
int main()
{
    cin >> n >> m >> k;
    ll low = 1, h = n * m;
    while (low < h)
    {
        ll mid = (low + h + 1) / 2;
        ll cnt = com(mid);
        if (cnt >= k)
            low = mid;
        else
            h = mid - 1;
    }
    cout << low;
    return 0;
}
